package com.example.utils;

import java.util.Random;

import com.example.dianping.R;

import android.R.string;

public class MyUtils {
	
	
	public static final int RequestLoginCode = 1;
	public static final int RequestCityCode = 2;
	public static final int RequestRegisterCode = 3;

	// 主页加载的数据项和图片
	public static String[] navsSort = { "美食", "电影", "酒店", "KTV", "自助餐", "休闲娱乐",
			"旅游", "购物", "都市丽人", "母婴", "女装", "美妆", "户外运动", "生活服务", "全部" };
	public static int[] navsSortImages = { R.drawable.nav_food1,
			R.drawable.nav_movie2, R.drawable.nav_hotel3, R.drawable.nav_ktv4,
			R.drawable.nav_zizhucan5, R.drawable.nav_relax6,
			R.drawable.nav_shoppingmall8, R.drawable.nav_lvyou7,
			R.drawable.nav_beauty9, R.drawable.nav_baby10,
			R.drawable.nav_nvzhuang11, R.drawable.nav_imarry12,
			R.drawable.nav_huwai13, R.drawable.nav_jiazhuang14,
			R.drawable.nav_all15 };

	public static String[] allCategroy = { "全部分类", "今日新单", "美食", "休闲娱乐", "电影",
			"生活服务", "写真生活", "酒店", "旅游", "都市丽人", "教育培训", "抽奖公益", "购物" };

	public static int[] allCategroyImages = { R.drawable.all1,
			R.drawable.jinri2, R.drawable.meishi3, R.drawable.xiuxian4,
			R.drawable.dianying5, R.drawable.fuwu6, R.drawable.xiezhen7,
			R.drawable.hotel8, R.drawable.lvyou9, R.drawable.liren10,
			R.drawable.xuexi11, R.drawable.chou12, R.drawable.buy13 };

	public static long allCategoryNumber[] = new long[allCategroy.length + 5];

	//random Vertify_Code produce
	private static final String RANDOMS = "1234567890qwertyuiopasdfghjklzxcvbnmQWERTYUIOPASDFGHJKLZXCVBNM";
	public static String getRandom(int num){
		StringBuffer sbf = new StringBuffer();
		for (int i = 0; i < num; i++) {
			int random = (int)(Math.random()*RANDOMS.length());
			sbf.append(RANDOMS.charAt(random));
		}
		return sbf.toString();
	}
	
}
